package cemp.controller;

import cemp.common.dto.Response;
import cemp.entity.StockDailyMessage;
import cemp.service.MessageService;
import lombok.AllArgsConstructor;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * @author xshibai
 * @date 2025年07月25日 15:23
 */
@RestController
@AllArgsConstructor
@RequestMapping("/message")
public class MessageController {

    @Autowired
    MessageService messageService;

    @GetMapping("/getall")
    public Response<List<StockDailyMessage>> getAll() {
        return Response.success(messageService.getAll());
    }


}
